home *** CD-ROM | disk | FTP | other *** search
/ The CICA Windows Explosion! / The CICA Windows Explosion! - Disc 2.iso / programr / mathstud.zip / GINPUT.M < prev    next >
Text File  |  1993-06-16  |  379b  |  18 lines

  1. function [x,y,button]=ginput(np,sc)
  2. %[x,y,button]=ginput(np,sc)
  3. %obtain graphic input from the user (A wrapper for the built-in _ginput)
  4.  
  5. %       S.Halevy 7/31/92
  6. %       Copyright (c) 1992 by the MathWizards
  7.  
  8. if nargin==1
  9.    t1=_ginput(np);
  10. elseif nargin>=2
  11.    t1=_ginput(np,sc);
  12. else
  13.    error('no input arguments')
  14. end
  15. x=t1(1,:)';
  16. y=t1(2,:)';
  17. button=t1(3,:)';
  18.